#ifndef LINESEGMENT_H
#define LINESEGMENT_H

#include "Vector2D.h"

class LineSegment 
{
private:
	Vector2D from;
	Vector2D to;
	Vector2D normal;

public:
	LineSegment(const float fromX, const float fromY, const float toX, const float toY);
	LineSegment(const Vector2D &from, const Vector2D &to);
	Vector2D GetFromPoint() const {return from;}
	Vector2D GetToPoint() const {return to;}
	Vector2D GetNormal() const {return normal;}
	// BONUS
	bool IntersectsWith(const LineSegment &seg) const;
};

#endif